#!/usr/bin/env python
#coding=utf-8 

# 可变参数 关键字变量参数
def fnc(arg1, arg2='defaultB', **vargsd):
	print 'formal arg1:', arg1
	print 'formal arg2:', arg2
	for eachline in vargsd.keys():
		print 'key %s  %s' % \
			(eachline, str(vargsd[eachline]))
# 可变参数 非关键子可变参数
def fncc(arg1, arg2='defaultB', *vargsd):
	print 'formal arg1:', arg1
	print 'formal arg2:', arg2
	for eachline in vargsd:
		print ' %s  ' % \
			(eachline)

# 可以是使用  newfoo(*(元组对应非关键字),**{对应关键字})
if __name__  == '__main__':
	fnc(1,2,c=3,d=4)
	fncc(1, 2, 3, 4)
